<!DOCTYPE html>
<!-- Created by huanggw on 2015/11/7. -->
<html ng-app="regist">
<head lang="en">
    <meta charset="UTF-8">
    <title>注册</title>
    <script src="http://apps.bdimg.com/libs/angular.js/1.5.0-beta.0/angular.min.js"></script>
    <script src="/javascripts/server.js"></script>
    <script src="/javascripts/regist.js"></script>
    <link rel='stylesheet' href='/stylesheets/header.css' />
    <link rel='stylesheet' href='/stylesheets/reg_login.css' />
</head>
<body ng-controller="regCtrl">
<div id="header"><a href="/">SchoolGate3D</a></div>
<div style="width: 100%; height: calc(100% - 36px);overflow: hidden;">
    <div class="templete slide">
        <div style="float:left; background: #eeeeee; height: 100%; width: 100%">
            <div class="wrapper {{status}}">
                <div class="container">
                    <h1>Welcome</h1>
                    <form class="form" name="regform" novalidate=”novalidate” ng-submit="regForm()" id="form">
                        <input type="text" name="username" ng-model="username" placeholder="用户名(字母/数字/下划线)" ng-pattern="/^[a-zA-Z0-9_]+/" ng-minlength="3" ng-maxlength="10" required>
                        <div class="error" ng-show="regform.username.$dirty && regform.username.$invalid">填写不正确</div>
                        <input type="email" name="useremail" ng-model="useremail" placeholder="邮箱" required>
                        <div class="error" ng-show="regform.useremail.$dirty && regform.useremail.$invalid">格式不正确</div>
                        <input type="password" name="password" ng-model="password" placeholder="密码(6-13位)" ng-pattern="/^[a-zA-Z0-9_]+/" ng-minlength="6" ng-maxlength="13" required>
                        <div class="error" ng-show="regform.password.$dirty && regform.password.$invalid">不符合要求</div>
                        <input type="password" name="comfirm" ng-model="comfirm" placeholder="确认密码" required>
                        <div class="error" ng-show="regform.comfirm.$dirty && (regform.comfirm.$invalid || password!=comfirm)">两次密码不一致</div>
                        <button type="submit" id="reg-button" ng-disabled="regform.$invalid">注册</button>
                        <div class="tip">已有账号,<a href="/login">现在登录</a>或<a href="/">返回首页</a></div>
                    </form>
                    <div class="success" id="success">{{regTip}}<br>
                        <a ng-show="regStatus == 0" href="/regist">重新注册</a><span ng-show="regStatus == 0" style="font-size: small">或</span>
                        <a href="/login">现在登录</a><span style="font-size: small">或</span>
                        <a href="/">返回首页</a>
                    </div>
                </div>
                <ul class="bg-bubbles">
                    <li></li>
                    <li></li>
                    <li></li>
                    <li></li>
                    <li></li>
                    <li></li>
                    <li></li>
                    <li></li>
                    <li></li>
                    <li></li>
                </ul>

            </div>
        </div>
    </div>
</div>
</body>
</html>